CREATE TABLE [dbo].[tb_TrackingDePasos]
(
[idTrackingPasos] [int] NOT NULL IDENTITY(1, 1),
[Tracking] [int] NOT NULL,
[Paso] [int] NOT NULL,
[VistoBueno] [varchar] (1) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[Observacion] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Documento] [int] NULL,
[Decision] [int] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[tb_TrackingDePasos] ADD CONSTRAINT [PK_tb_TrackingDePasos] PRIMARY KEY NONCLUSTERED  ([idTrackingPasos]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[tb_TrackingDePasos] ADD CONSTRAINT [FK_tb_TrackingDePasos_tb_Documentos] FOREIGN KEY ([Documento]) REFERENCES [dbo].[tb_Documentos] ([idDocumento])
GO
ALTER TABLE [dbo].[tb_TrackingDePasos] WITH NOCHECK ADD CONSTRAINT [FK_tb_TrackingDePasos_tb_Pasos] FOREIGN KEY ([Paso]) REFERENCES [dbo].[tb_Pasos] ([idPaso])
GO
ALTER TABLE [dbo].[tb_TrackingDePasos] WITH NOCHECK ADD CONSTRAINT [FK_tb_TrackingDePasos_tb_Tracking] FOREIGN KEY ([Tracking]) REFERENCES [dbo].[tb_Tracking] ([idTracking])
GO
